const Router = require('koa-router')
const router = new Router()

router.get('/gsgk/', async (ctx) => {
  ctx.response.status = 200
  ctx.config.nav[1].checked = true
  ctx.config.title = '公司概况_元翔职校'
  ctx.config.description = '公司概况，元翔职校'
  ctx.config.keyword = '公司概况,元翔职校'
  ctx.config.banner = `${ctx.config.host}/imgs/banner2.jpg`

  await ctx.render('zjyx.ejs', {
    config: ctx.config,
    menu: [{
      title: '公司概况',
      pinyin: 'gsgk',
      checked: true
    }, {
      title: '荣誉资质',
      pinyin: 'ryzz',
      checked: false
    }],
    pathname: '/gsgk/'
  })
})

router.get('/ryzz/', async (ctx) => {
  ctx.response.status = 200
  ctx.config.nav[1].checked = true
  ctx.config.title = '荣誉资质_元翔职校'
  ctx.config.description = '荣誉资质，元翔职校'
  ctx.config.keyword = '荣誉资质,元翔职校'
  ctx.config.banner = `${ctx.config.host}/imgs/banner2.jpg`

  await ctx.render('zjyx.ejs', {
    config: ctx.config,
    menu: [{
      title: '公司概况',
      pinyin: 'gsgk',
      checked: false
    }, {
      title: '荣誉资质',
      pinyin: 'ryzz',
      checked: true
    }],
    honor: [{
      title: '创业云星',
      src: `${ctx.config.host}/imgs/honor5.jpg`
    }, {
      title: '拥军优属先进单位',
      src: `${ctx.config.host}/imgs/honor6.jpg`
    }, {
      title: '劳动用工诚信单位',
      src: `${ctx.config.host}/imgs/honor8.jpg`
    }],
    pathname: '/ryzz/'
  })
})

module.exports = router